// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
// import Vue from 'vue'
import App from './App'
import router from './router'
import store from './store'

// 引入vant
// import Vant from 'vant';
// import 'vant/lib/index.css';
// Vue.use(vant);

// 引入vueI18n
import VueI18n from 'vue-i18n';
Vue.use(VueI18n);
const i18n = new VueI18n({
  locale: localStorage.getItem("language") ?
    localStorage.getItem("language") : 'zh_CN', // 语言标识
  //this.$i18n.locale // 通过切换locale的值来实现语言切换
  messages: {
    'zh_CN': require('./i18n/zh'), // 中文语言包
    'en_US': require('./i18n/en') // 英文语言包
  }
})

// 引入mui 主要是为了实现保存图片功能
import mui from "./assets/js/mui.min.js"
Vue.prototype.mui = mui;

// import echarts from 'echarts'
Vue.prototype.$echarts = echarts

import Navigation from 'vue-navigation'
Vue.use(Navigation, {
  router,
  store,
  moduleName: 'navigation',
  keyName: 'v'
})
/* eslint-disable no-new */
new Vue({
  el: '#app',
  i18n,
  router,
  store,
  components: {
    App
  },
  template: '<App/>'
})
